const dz = 'http://192.168.55.201:3002/my/auth'
function get1() {
    $.get(dz + '/content', res => {
        const { data } = res
        const html_arr = data[0].map(item => {
            return `
            <div class="article-lwrap">
            <div class="imgCon">
                <img src="${item.img}">
            </div>
            <div class="list-content">
                <p>${item.article} <span>收藏</span></p>
                <div class="list-bottom">
                    <button>${item.type}</button>
                    <img src="./img/眼睛 (1).png" alt="">
                    <span>${item.watch}</span>
                    <a href="#">${item.name}</a>
                    <a href="#">${item.major}</a>
                    <div class="createTime">12.15</div>
                </div>
            </div>
        </div>
            `
        })
        $('.articleCon').html(html_arr)
    })
}
get1()

function get2() {
    $.get(dz + '/user', res => {
        const { data } = res
        console.log(data)
        const html_arr = data.map(item => {
            return `
                <li>
                <div class="imgCon"><img src="${item.img}"></div>
                <div class="text">
                    <p class="name">${item.name}</p>
                    <p class="clearfix">
                        <span>${item.article}</span>
                        <span class="span">${item.fans}</span>
                    </p>
                </div>
                <button>+关注</button>
            </li>
            `
        })
        $('.personList').html(html_arr)
    })
}
get2()